from django.shortcuts import render
from django.http import HttpResponse
from django.urls import reverse
from django.shortcuts import redirect
def redirect_view(request):
    url=reverse('myapp:hello_world')
    return redirect(url)
""" def myapp(request):
    value='This is test!'
    print(value)
    return render(request, 'myapp.html') """

def myapp(request):
    return HttpResponse('Hello CaoSong!')
def mysum(request,sumA,sumB):
    sum=sumA+sumB
    return HttpResponse(f'The sum of {sumA} and {sumB}={sum}')
def mydate(request,year):
    return HttpResponse(f'the post- number is {year}')
def hello_world(request):
    return HttpResponse("Hello, Django!")
def some_view(request):
    return render(request,'templates.html')
